<!DOCTYPE html >
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <meta http-equiv="X-UA-Compatible" content="IE=Edge,chrome=1" />
    <title>后台登录</title>
    <meta name="keywords" content="后台登录" />
    <meta name="description" content="后台登录" />
    <link href="/static/css/layout.css" rel="stylesheet" />
    <link href="/static/css/login.css" rel="stylesheet"/>
    <style type="text/css">
        .ibar { display: none; }
    </style>
</head>

<body class="login-bg">
    <div class="main ">
        <!--登录-->
        <div class="login-dom login-max">
            <div class="logo text-center">
                 <h1>后台登录</h1>
            </div>
            <div class="login container " id="login">
    
                <form class="login-form" action="/ajaxlogin" method="post" autocomplete="off">
                    <div class="login-box border text-small" id="box">
                        <div class="name border-bottom">
                            <input type="text" placeholder="手机/邮箱/账号（随便填）" id="username" name="username" datatype="*" nullmsg="请填写帐号信息" />
                        </div>
                        <div class="pwd">
                            <input type="password" placeholder="密码（随便填）" datatype="*" id="password" name="password"   nullmsg="请填写帐号密码" />
                        </div>
                    </div>
                    <input type="submit" class="btn text-center login-btn" value="立即登录" />
                </form> 
            </div>
        </div>
        <div class="footer text-center text-small ie">
            Copyright 2017 版权所有 ©rx.tang    
        </div>
        <div class="popupDom">
            <div class="popup text-default">
            </div>
        </div>
    </div>
</body>
<script src="/static/lib/jQuery/jquery.min.js"></script>
<script src="/static/plugins/validator/validator.js"></script>
<script type="text/javascript">
    function popup_msg(msg) {
        $(".popup").html("" + msg + "");
        $(".popupDom").animate({
            "top": "0px"
        }, 400);
        setTimeout(function () {
            $(".popupDom").animate({
                "top": "-40px"
            }, 400);
        }, 2000);
    }

    /*动画（注册）*/
    $(document).ready(function (e) {
        $("input[name=username]").focus();
         $('.login-form').Validform({
         	ajaxPost: true,
         	tiptype: function(msg) {
         		if (msg) popup_msg('' + msg + '');
         	},
         	callback: function(ret) {
         		popup_msg('' + ret.msg + '');
         		if (ret.status == 1) {
         			if (ret.uc_user_synlogin) {
         				$("body").append(ret.uc_user_synlogin);
         			}
         			setTimeout("window.location='" + ret.url + "'", 2000);
         		}
         	}
         });
    });
</script>
</html>